3.1.42 \(\int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx\) [42]

3.1.42.1 Optimal result
3.1.42.2 Mathematica [C] (verified)
3.1.42.3 Rubi [A] (verified)
3.1.42.4 Maple [A] (verified)
3.1.42.5 Fricas [A] (verification not implemented)
3.1.42.6 Sympy [F]
3.1.42.7 Maxima [B] (verification not implemented)
3.1.42.8 Giac [A] (verification not implemented)
3.1.42.9 Mupad [B] (verification not implemented)

3.1.42.1 Optimal result

Integrand size = 32, antiderivative size = 164 \[ \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx=\frac {105 c^5 \text {arctanh}(\sin (e+f x))}{2 a^2 f}-\frac {84 c^5 \tan (e+f x)}{a^2 f}+\frac {63 c^5 \sec (e+f x) \tan (e+f x)}{2 a^2 f}-\frac {6 c^2 (c-c \sec (e+f x))^3 \tan (e+f x)}{f \left (a^2+a^2 \sec (e+f x)\right )}+\frac {2 c (c-c \sec (e+f x))^4 \tan (e+f x)}{3 f (a+a \sec (e+f x))^2}-\frac {7 c^5 \tan ^3(e+f x)}{a^2 f} \]

output
105/2*c^5*arctanh(sin(f*x+e))/a^2/f-84*c^5*tan(f*x+e)/a^2/f+63/2*c^5*sec(f 
*x+e)*tan(f*x+e)/a^2/f-6*c^2*(c-c*sec(f*x+e))^3*tan(f*x+e)/f/(a^2+a^2*sec( 
f*x+e))+2/3*c*(c-c*sec(f*x+e))^4*tan(f*x+e)/f/(a+a*sec(f*x+e))^2-7*c^5*tan 
(f*x+e)^3/a^2/f
 
3.1.42.2 Mathematica [C] (verified)

Result contains higher order function than in optimal. Order 5 vs. order 3 in optimal.

Time = 2.92 (sec) , antiderivative size = 75, normalized size of antiderivative = 0.46 \[ \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx=-\frac {32 c^5 \operatorname {Hypergeometric2F1}\left (-\frac {9}{2},-\frac {3}{2},-\frac {1}{2},\frac {1}{2} (1+\sec (e+f x))\right ) \sqrt {2-2 \sec (e+f x)} \tan (e+f x)}{3 a^2 f (-1+\sec (e+f x)) (1+\sec (e+f x))^2} \]

input
Integrate[(Sec[e + f*x]*(c - c*Sec[e + f*x])^5)/(a + a*Sec[e + f*x])^2,x]
 
output
(-32*c^5*Hypergeometric2F1[-9/2, -3/2, -1/2, (1 + Sec[e + f*x])/2]*Sqrt[2 
- 2*Sec[e + f*x]]*Tan[e + f*x])/(3*a^2*f*(-1 + Sec[e + f*x])*(1 + Sec[e + 
f*x])^2)
 
3.1.42.3 Rubi [A] (verified)

Time = 0.66 (sec) , antiderivative size = 162, normalized size of antiderivative = 0.99, number of steps used = 7, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.219, Rules used = {3042, 4445, 3042, 4445, 3042, 4278, 2009}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a \sec (e+f x)+a)^2} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \left (c-c \csc \left (e+f x+\frac {\pi }{2}\right )\right )^5}{\left (a \csc \left (e+f x+\frac {\pi }{2}\right )+a\right )^2}dx\)

\(\Big \downarrow \) 4445

\(\displaystyle \frac {2 c \tan (e+f x) (c-c \sec (e+f x))^4}{3 f (a \sec (e+f x)+a)^2}-\frac {3 c \int \frac {\sec (e+f x) (c-c \sec (e+f x))^4}{\sec (e+f x) a+a}dx}{a}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {2 c \tan (e+f x) (c-c \sec (e+f x))^4}{3 f (a \sec (e+f x)+a)^2}-\frac {3 c \int \frac {\csc \left (e+f x+\frac {\pi }{2}\right ) \left (c-c \csc \left (e+f x+\frac {\pi }{2}\right )\right )^4}{\csc \left (e+f x+\frac {\pi }{2}\right ) a+a}dx}{a}\)

\(\Big \downarrow \) 4445

\(\displaystyle \frac {2 c \tan (e+f x) (c-c \sec (e+f x))^4}{3 f (a \sec (e+f x)+a)^2}-\frac {3 c \left (\frac {2 c \tan (e+f x) (c-c \sec (e+f x))^3}{f (a \sec (e+f x)+a)}-\frac {7 c \int \sec (e+f x) (c-c \sec (e+f x))^3dx}{a}\right )}{a}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {2 c \tan (e+f x) (c-c \sec (e+f x))^4}{3 f (a \sec (e+f x)+a)^2}-\frac {3 c \left (\frac {2 c \tan (e+f x) (c-c \sec (e+f x))^3}{f (a \sec (e+f x)+a)}-\frac {7 c \int \csc \left (e+f x+\frac {\pi }{2}\right ) \left (c-c \csc \left (e+f x+\frac {\pi }{2}\right )\right )^3dx}{a}\right )}{a}\)

\(\Big \downarrow \) 4278

\(\displaystyle \frac {2 c \tan (e+f x) (c-c \sec (e+f x))^4}{3 f (a \sec (e+f x)+a)^2}-\frac {3 c \left (\frac {2 c \tan (e+f x) (c-c \sec (e+f x))^3}{f (a \sec (e+f x)+a)}-\frac {7 c \int \left (-c^3 \sec ^4(e+f x)+3 c^3 \sec ^3(e+f x)-3 c^3 \sec ^2(e+f x)+c^3 \sec (e+f x)\right )dx}{a}\right )}{a}\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {2 c \tan (e+f x) (c-c \sec (e+f x))^4}{3 f (a \sec (e+f x)+a)^2}-\frac {3 c \left (\frac {2 c \tan (e+f x) (c-c \sec (e+f x))^3}{f (a \sec (e+f x)+a)}-\frac {7 c \left (\frac {5 c^3 \text {arctanh}(\sin (e+f x))}{2 f}-\frac {c^3 \tan ^3(e+f x)}{3 f}-\frac {4 c^3 \tan (e+f x)}{f}+\frac {3 c^3 \tan (e+f x) \sec (e+f x)}{2 f}\right )}{a}\right )}{a}\)

input
Int[(Sec[e + f*x]*(c - c*Sec[e + f*x])^5)/(a + a*Sec[e + f*x])^2,x]
 
output
(2*c*(c - c*Sec[e + f*x])^4*Tan[e + f*x])/(3*f*(a + a*Sec[e + f*x])^2) - ( 
3*c*((2*c*(c - c*Sec[e + f*x])^3*Tan[e + f*x])/(f*(a + a*Sec[e + f*x])) - 
(7*c*((5*c^3*ArcTanh[Sin[e + f*x]])/(2*f) - (4*c^3*Tan[e + f*x])/f + (3*c^ 
3*Sec[e + f*x]*Tan[e + f*x])/(2*f) - (c^3*Tan[e + f*x]^3)/(3*f)))/a))/a
 

3.1.42.3.1 Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4278
Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + 
(a_))^(m_), x_Symbol] :> Int[ExpandTrig[(a + b*csc[e + f*x])^m*(d*csc[e + f 
*x])^n, x], x] /; FreeQ[{a, b, d, e, f, m, n}, x] && EqQ[a^2 - b^2, 0] && I 
GtQ[m, 0] && RationalQ[n]
 

rule 4445
Int[csc[(e_.) + (f_.)*(x_)]*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_)*(cs 
c[(e_.) + (f_.)*(x_)]*(d_.) + (c_))^(n_.), x_Symbol] :> Simp[2*a*c*Cot[e + 
f*x]*(a + b*Csc[e + f*x])^m*((c + d*Csc[e + f*x])^(n - 1)/(b*f*(2*m + 1))), 
 x] - Simp[d*((2*n - 1)/(b*(2*m + 1)))   Int[Csc[e + f*x]*(a + b*Csc[e + f* 
x])^(m + 1)*(c + d*Csc[e + f*x])^(n - 1), x], x] /; FreeQ[{a, b, c, d, e, f 
}, x] && EqQ[b*c + a*d, 0] && EqQ[a^2 - b^2, 0] && IGtQ[n, 0] && LtQ[m, -2^ 
(-1)] && IntegerQ[2*m]
 
3.1.42.4 Maple [A] (verified)

Time = 1.45 (sec) , antiderivative size = 155, normalized size of antiderivative = 0.95

method result size
derivativedivides \(\frac {16 c^{5} \left (-\frac {\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{3}}{3}-4 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )+\frac {1}{48 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )^{3}}-\frac {1}{4 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )^{2}}+\frac {55}{32 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )}+\frac {105 \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )}{32}+\frac {1}{48 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )^{3}}+\frac {1}{4 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )^{2}}+\frac {55}{32 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )}-\frac {105 \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )}{32}\right )}{f \,a^{2}}\) \(155\)
default \(\frac {16 c^{5} \left (-\frac {\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{3}}{3}-4 \tan \left (\frac {f x}{2}+\frac {e}{2}\right )+\frac {1}{48 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )^{3}}-\frac {1}{4 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )^{2}}+\frac {55}{32 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )}+\frac {105 \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )}{32}+\frac {1}{48 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )^{3}}+\frac {1}{4 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )^{2}}+\frac {55}{32 \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )}-\frac {105 \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )}{32}\right )}{f \,a^{2}}\) \(155\)
parallelrisch \(-\frac {1969 \left (\frac {630 \left (\cos \left (3 f x +3 e \right )+3 \cos \left (f x +e \right )\right ) \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )}{1969}+\frac {630 \left (-\cos \left (3 f x +3 e \right )-3 \cos \left (f x +e \right )\right ) \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )}{1969}+\tan \left (\frac {f x}{2}+\frac {e}{2}\right ) \sec \left (\frac {f x}{2}+\frac {e}{2}\right )^{2} \left (\cos \left (f x +e \right )+\frac {1192 \cos \left (2 f x +2 e \right )}{1969}+\frac {679 \cos \left (3 f x +3 e \right )}{1969}+\frac {247 \cos \left (4 f x +4 e \right )}{1969}+\frac {953}{1969}\right )\right ) c^{5}}{12 f \,a^{2} \left (\cos \left (3 f x +3 e \right )+3 \cos \left (f x +e \right )\right )}\) \(161\)
risch \(-\frac {i c^{5} \left (309 \,{\mathrm e}^{8 i \left (f x +e \right )}+969 \,{\mathrm e}^{7 i \left (f x +e \right )}+1693 \,{\mathrm e}^{6 i \left (f x +e \right )}+3027 \,{\mathrm e}^{5 i \left (f x +e \right )}+2901 \,{\mathrm e}^{4 i \left (f x +e \right )}+3247 \,{\mathrm e}^{3 i \left (f x +e \right )}+1995 \,{\mathrm e}^{2 i \left (f x +e \right )}+1173 \,{\mathrm e}^{i \left (f x +e \right )}+494\right )}{3 a^{2} f \left (1+{\mathrm e}^{2 i \left (f x +e \right )}\right )^{3} \left ({\mathrm e}^{i \left (f x +e \right )}+1\right )^{3}}+\frac {105 c^{5} \ln \left ({\mathrm e}^{i \left (f x +e \right )}+i\right )}{2 a^{2} f}-\frac {105 c^{5} \ln \left ({\mathrm e}^{i \left (f x +e \right )}-i\right )}{2 a^{2} f}\) \(178\)
norman \(\frac {\frac {105 c^{5} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{a f}-\frac {490 c^{5} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{3}}{a f}+\frac {896 c^{5} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{5}}{a f}-\frac {790 c^{5} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{7}}{a f}+\frac {965 c^{5} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{9}}{3 a f}-\frac {112 c^{5} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{11}}{3 a f}-\frac {16 c^{5} \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{13}}{3 a f}}{\left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2}-1\right )^{5} a}-\frac {105 c^{5} \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )-1\right )}{2 a^{2} f}+\frac {105 c^{5} \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )+1\right )}{2 a^{2} f}\) \(220\)

input
int(sec(f*x+e)*(c-c*sec(f*x+e))^5/(a+a*sec(f*x+e))^2,x,method=_RETURNVERBO 
SE)
 
output
16/f*c^5/a^2*(-1/3*tan(1/2*f*x+1/2*e)^3-4*tan(1/2*f*x+1/2*e)+1/48/(tan(1/2 
*f*x+1/2*e)+1)^3-1/4/(tan(1/2*f*x+1/2*e)+1)^2+55/32/(tan(1/2*f*x+1/2*e)+1) 
+105/32*ln(tan(1/2*f*x+1/2*e)+1)+1/48/(tan(1/2*f*x+1/2*e)-1)^3+1/4/(tan(1/ 
2*f*x+1/2*e)-1)^2+55/32/(tan(1/2*f*x+1/2*e)-1)-105/32*ln(tan(1/2*f*x+1/2*e 
)-1))
 
3.1.42.5 Fricas [A] (verification not implemented)

Time = 0.27 (sec) , antiderivative size = 210, normalized size of antiderivative = 1.28 \[ \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx=\frac {315 \, {\left (c^{5} \cos \left (f x + e\right )^{5} + 2 \, c^{5} \cos \left (f x + e\right )^{4} + c^{5} \cos \left (f x + e\right )^{3}\right )} \log \left (\sin \left (f x + e\right ) + 1\right ) - 315 \, {\left (c^{5} \cos \left (f x + e\right )^{5} + 2 \, c^{5} \cos \left (f x + e\right )^{4} + c^{5} \cos \left (f x + e\right )^{3}\right )} \log \left (-\sin \left (f x + e\right ) + 1\right ) - 2 \, {\left (494 \, c^{5} \cos \left (f x + e\right )^{4} + 679 \, c^{5} \cos \left (f x + e\right )^{3} + 102 \, c^{5} \cos \left (f x + e\right )^{2} - 17 \, c^{5} \cos \left (f x + e\right ) + 2 \, c^{5}\right )} \sin \left (f x + e\right )}{12 \, {\left (a^{2} f \cos \left (f x + e\right )^{5} + 2 \, a^{2} f \cos \left (f x + e\right )^{4} + a^{2} f \cos \left (f x + e\right )^{3}\right )}} \]

input
integrate(sec(f*x+e)*(c-c*sec(f*x+e))^5/(a+a*sec(f*x+e))^2,x, algorithm="f 
ricas")
 
output
1/12*(315*(c^5*cos(f*x + e)^5 + 2*c^5*cos(f*x + e)^4 + c^5*cos(f*x + e)^3) 
*log(sin(f*x + e) + 1) - 315*(c^5*cos(f*x + e)^5 + 2*c^5*cos(f*x + e)^4 + 
c^5*cos(f*x + e)^3)*log(-sin(f*x + e) + 1) - 2*(494*c^5*cos(f*x + e)^4 + 6 
79*c^5*cos(f*x + e)^3 + 102*c^5*cos(f*x + e)^2 - 17*c^5*cos(f*x + e) + 2*c 
^5)*sin(f*x + e))/(a^2*f*cos(f*x + e)^5 + 2*a^2*f*cos(f*x + e)^4 + a^2*f*c 
os(f*x + e)^3)
 
3.1.42.6 Sympy [F]

\[ \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx=- \frac {c^{5} \left (\int \left (- \frac {\sec {\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} + 2 \sec {\left (e + f x \right )} + 1}\right )\, dx + \int \frac {5 \sec ^{2}{\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} + 2 \sec {\left (e + f x \right )} + 1}\, dx + \int \left (- \frac {10 \sec ^{3}{\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} + 2 \sec {\left (e + f x \right )} + 1}\right )\, dx + \int \frac {10 \sec ^{4}{\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} + 2 \sec {\left (e + f x \right )} + 1}\, dx + \int \left (- \frac {5 \sec ^{5}{\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} + 2 \sec {\left (e + f x \right )} + 1}\right )\, dx + \int \frac {\sec ^{6}{\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )} + 2 \sec {\left (e + f x \right )} + 1}\, dx\right )}{a^{2}} \]

input
integrate(sec(f*x+e)*(c-c*sec(f*x+e))**5/(a+a*sec(f*x+e))**2,x)
 
output
-c**5*(Integral(-sec(e + f*x)/(sec(e + f*x)**2 + 2*sec(e + f*x) + 1), x) + 
 Integral(5*sec(e + f*x)**2/(sec(e + f*x)**2 + 2*sec(e + f*x) + 1), x) + I 
ntegral(-10*sec(e + f*x)**3/(sec(e + f*x)**2 + 2*sec(e + f*x) + 1), x) + I 
ntegral(10*sec(e + f*x)**4/(sec(e + f*x)**2 + 2*sec(e + f*x) + 1), x) + In 
tegral(-5*sec(e + f*x)**5/(sec(e + f*x)**2 + 2*sec(e + f*x) + 1), x) + Int 
egral(sec(e + f*x)**6/(sec(e + f*x)**2 + 2*sec(e + f*x) + 1), x))/a**2
 
3.1.42.7 Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 765 vs. \(2 (160) = 320\).

Time = 0.23 (sec) , antiderivative size = 765, normalized size of antiderivative = 4.66 \[ \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx=\text {Too large to display} \]

input
integrate(sec(f*x+e)*(c-c*sec(f*x+e))^5/(a+a*sec(f*x+e))^2,x, algorithm="m 
axima")
 
output
-1/6*(c^5*(4*(9*sin(f*x + e)/(cos(f*x + e) + 1) - 20*sin(f*x + e)^3/(cos(f 
*x + e) + 1)^3 + 15*sin(f*x + e)^5/(cos(f*x + e) + 1)^5)/(a^2 - 3*a^2*sin( 
f*x + e)^2/(cos(f*x + e) + 1)^2 + 3*a^2*sin(f*x + e)^4/(cos(f*x + e) + 1)^ 
4 - a^2*sin(f*x + e)^6/(cos(f*x + e) + 1)^6) + (27*sin(f*x + e)/(cos(f*x + 
 e) + 1) + sin(f*x + e)^3/(cos(f*x + e) + 1)^3)/a^2 - 30*log(sin(f*x + e)/ 
(cos(f*x + e) + 1) + 1)/a^2 + 30*log(sin(f*x + e)/(cos(f*x + e) + 1) - 1)/ 
a^2) + 5*c^5*(6*(3*sin(f*x + e)/(cos(f*x + e) + 1) - 5*sin(f*x + e)^3/(cos 
(f*x + e) + 1)^3)/(a^2 - 2*a^2*sin(f*x + e)^2/(cos(f*x + e) + 1)^2 + a^2*s 
in(f*x + e)^4/(cos(f*x + e) + 1)^4) + (21*sin(f*x + e)/(cos(f*x + e) + 1) 
+ sin(f*x + e)^3/(cos(f*x + e) + 1)^3)/a^2 - 21*log(sin(f*x + e)/(cos(f*x 
+ e) + 1) + 1)/a^2 + 21*log(sin(f*x + e)/(cos(f*x + e) + 1) - 1)/a^2) + 10 
*c^5*((15*sin(f*x + e)/(cos(f*x + e) + 1) + sin(f*x + e)^3/(cos(f*x + e) + 
 1)^3)/a^2 - 12*log(sin(f*x + e)/(cos(f*x + e) + 1) + 1)/a^2 + 12*log(sin( 
f*x + e)/(cos(f*x + e) + 1) - 1)/a^2 + 12*sin(f*x + e)/((a^2 - a^2*sin(f*x 
 + e)^2/(cos(f*x + e) + 1)^2)*(cos(f*x + e) + 1))) + 10*c^5*((9*sin(f*x + 
e)/(cos(f*x + e) + 1) + sin(f*x + e)^3/(cos(f*x + e) + 1)^3)/a^2 - 6*log(s 
in(f*x + e)/(cos(f*x + e) + 1) + 1)/a^2 + 6*log(sin(f*x + e)/(cos(f*x + e) 
 + 1) - 1)/a^2) + 5*c^5*(3*sin(f*x + e)/(cos(f*x + e) + 1) + sin(f*x + e)^ 
3/(cos(f*x + e) + 1)^3)/a^2 - c^5*(3*sin(f*x + e)/(cos(f*x + e) + 1) - sin 
(f*x + e)^3/(cos(f*x + e) + 1)^3)/a^2)/f
 
3.1.42.8 Giac [A] (verification not implemented)

Time = 0.41 (sec) , antiderivative size = 156, normalized size of antiderivative = 0.95 \[ \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx=\frac {\frac {315 \, c^{5} \log \left ({\left | \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) + 1 \right |}\right )}{a^{2}} - \frac {315 \, c^{5} \log \left ({\left | \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) - 1 \right |}\right )}{a^{2}} + \frac {2 \, {\left (165 \, c^{5} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{5} - 280 \, c^{5} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{3} + 123 \, c^{5} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} - 1\right )}^{3} a^{2}} - \frac {32 \, {\left (a^{4} c^{5} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{3} + 12 \, a^{4} c^{5} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )\right )}}{a^{6}}}{6 \, f} \]

input
integrate(sec(f*x+e)*(c-c*sec(f*x+e))^5/(a+a*sec(f*x+e))^2,x, algorithm="g 
iac")
 
output
1/6*(315*c^5*log(abs(tan(1/2*f*x + 1/2*e) + 1))/a^2 - 315*c^5*log(abs(tan( 
1/2*f*x + 1/2*e) - 1))/a^2 + 2*(165*c^5*tan(1/2*f*x + 1/2*e)^5 - 280*c^5*t 
an(1/2*f*x + 1/2*e)^3 + 123*c^5*tan(1/2*f*x + 1/2*e))/((tan(1/2*f*x + 1/2* 
e)^2 - 1)^3*a^2) - 32*(a^4*c^5*tan(1/2*f*x + 1/2*e)^3 + 12*a^4*c^5*tan(1/2 
*f*x + 1/2*e))/a^6)/f
 
3.1.42.9 Mupad [B] (verification not implemented)

Time = 12.94 (sec) , antiderivative size = 170, normalized size of antiderivative = 1.04 \[ \int \frac {\sec (e+f x) (c-c \sec (e+f x))^5}{(a+a \sec (e+f x))^2} \, dx=\frac {55\,c^5\,{\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^5-\frac {280\,c^5\,{\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^3}{3}+41\,c^5\,\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}{f\,\left (a^2\,{\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^6-3\,a^2\,{\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^4+3\,a^2\,{\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^2-a^2\right )}-\frac {64\,c^5\,\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}{a^2\,f}-\frac {16\,c^5\,{\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )}^3}{3\,a^2\,f}+\frac {105\,c^5\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {e}{2}+\frac {f\,x}{2}\right )\right )}{a^2\,f} \]

input
int((c - c/cos(e + f*x))^5/(cos(e + f*x)*(a + a/cos(e + f*x))^2),x)
 
output
(55*c^5*tan(e/2 + (f*x)/2)^5 - (280*c^5*tan(e/2 + (f*x)/2)^3)/3 + 41*c^5*t 
an(e/2 + (f*x)/2))/(f*(3*a^2*tan(e/2 + (f*x)/2)^2 - 3*a^2*tan(e/2 + (f*x)/ 
2)^4 + a^2*tan(e/2 + (f*x)/2)^6 - a^2)) - (64*c^5*tan(e/2 + (f*x)/2))/(a^2 
*f) - (16*c^5*tan(e/2 + (f*x)/2)^3)/(3*a^2*f) + (105*c^5*atanh(tan(e/2 + ( 
f*x)/2)))/(a^2*f)